<?php

/*
|--------------------------------------------------------------------------
| Routes File
|--------------------------------------------------------------------------
|
| Here is where you will register all of the routes in an application.
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the controller to call when that URI is requested.
|
*/

Route::get('movie/{movie_id}', function($movie_id)
{
  return '电影' . $movie_id;
});

Route::get('movie/{movie_id}/review/{review_id?}', function($movie_id, $review_id = null)
{
  return '电影' . $movie_id. '里面的影评'.$review_id;
});

//
// Route::any('movie', function(){
//   return '电影';
// });

// Route::match(['get','post'],'movie', function(){
//   return '电影';
// });

Route::get('/', function () {
    return view('welcome');
});

// Route::get('movie', function(){
//   return '电影列表';
// });
//
// Route::post('movie', function()
// {
//   return '发布电影 ';
// });
//
// Route::put('movie', function()
// {
//   return '修改电影';
// });
//
// Route::delete('movie', function()
// {
//   return '删除电影';
// });
/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| This route group applies the "web" middleware group to every route
| it contains. The "web" middleware group is defined in your HTTP
| kernel and includes session state, CSRF protection, and more.
|
*/

Route::group(['middleware' => ['web']], function () {
    //
});
